<template>
  <router-link :to="{path:to}" class="my-cell">
    <div class="cell-left">
      <i :class="icon" v-if="icon" :style="iconstyle"></i>
      <p v-text="title"></p>
    </div>
    <div class="cell-right" v-if="value" >
      <p v-text="value"></p>
    </div>
  </router-link>
</template>

<script>
export default {
  name: 'my-cell',
  props: {
    to: {type: String},
    icon: {type: String},
    title: {type: String},
    value: {type: String},

    iconstyle: {type: String}
  }
};
</script>

<style scoped>
  .my-cell {
    display: flex;
    justify-content: space-between;

    text-decoration: none;
    border-bottom: 1px solid #eee;
  }
  .my-cell p {
    margin: 8px 0 0 0;
    line-height: 40px;
    font-size: 14px;
    color: #666;
  }
  .my-cell .cell-left {
    display: flex;
    align-items: center;
  }
  .my-cell .cell-left i {
    width: 30px;
    font-size: 25px;
    color: #FF9B01;
    position: relative;
    top: 2px;
  }
  .my-cell .cell-right p {
    color: #bbb;
  }

</style>